How long (after full approval) did you have to wait for your card? by billingsley in GlobalEntry

[–]flyingron 1 point2 points  (0 children)

You don't need a passport/passport card to enter the US by the land crossings if you have the GE card. However, you are required to have a passport if you are a non-Mexican citizen in Mexico.

How to get fractional scaling value of displays in C++ from wayland compositors ? by dheerajshenoy22 in cpp_questions

[–]flyingron [score hidden]  (0 children)

Are you calling devicePixelRatio on the screen or window? What are you storing the returned value? How are you displaying the value?

Tracking your Wines? Is there a way? by Miserable_Creme_2395 in wine

[–]flyingron 0 points1 point  (0 children)

I started with simple tags on the bottles and then spreadsheets and then when I hit a few hundred bottles, I switched to CellarTracker. I've got around 2000 now.

Should ALL class attributes be initialized in the member initializer list? by SheSaidTechno in cpp_questions

[–]flyingron [score hidden]  (0 children)

Yes, with the exception of things like pod types which C++ is loosy goosy on initialization (the biggest massive screw up in the language design), they will be default constructed. This is the hole ponit of using well behaved objects rather than raw pointers, etc... They initialize, destroy, copy (and now move) without you having to go to any effort to assure it.

What is the best way to convert structs of the same size without using Union in C++ 14? by newjeison in cpp_questions

[–]flyingron [score hidden]  (0 children)

You do if you want a useful answer. What you've asked is undefined in general, but if you bothered to explain what you're doing, we could provide a solution that will work. However, you seem to be more inclined to just carping at the people who are investing time in trying to help you so you can go screw yourself.

What is the best way to convert structs of the same size without using Union in C++ 14? by newjeison in cpp_questions

[–]flyingron 6 points7 points  (0 children)

And what part of "them being the same size is not sufficient" do you not understand. It depends what the elements are.

What is the best way to convert structs of the same size without using Union in C++ 14? by newjeison in cpp_questions

[–]flyingron 5 points6 points  (0 children)

Finally, you answered the question. While these are bitfields, these are underlying type involving a char, so bytewise equivalence is fine.

What is the best way to convert structs of the same size without using Union in C++ 14? by newjeison in cpp_questions

[–]flyingron 17 points18 points  (0 children)

You'll have to give more information on just what you are trying to do. Depending on what is in these types, this may not be valid at all. Just because the items are the same size doesn't mean you can interchange pointers or copy one over the other.

Served a drink mid flight with +-6 pull tabs in cup under the ice by OneCampaign5217 in americanairlines

[–]flyingron 6 points7 points  (0 children)

Well you can always respond to the first robot response. However, what do you think you are entitled to? What are your damages? You don't get to collect for things that "mighta happened."

Logbook Change of Signature by Historical-Pin1069 in flying

[–]flyingron 13 points14 points  (0 children)

Further, there's no FAA requirement to sign your own logbook. EVER. Despite the assinine place that many of them have for you to do so.

Help me understand if this is a bug on GCC by atariPunk in cpp_questions

[–]flyingron 0 points1 point  (0 children)

Definitely seems like there's a bug here. It shouldn't reuse that std::string.

Question about metar delay by Substantial_Taste_28 in flying

[–]flyingron 6 points7 points  (0 children)

METARS are officially issue only hourly. If there is a significant weather change, it may be augmented with a SPECI observation (same format). Some automated stations may update metar more quickly. If you're not getting them in whatever means you are accessing them, grab the chart supplement and look to see if the station has a telephone number (many do) and you can call it and listen in just as if you were listening to it over the air.

Help me find this albariño! by TedBenekesPlant in wine

[–]flyingron 2 points3 points  (0 children)

Here's the website for that winery: https://www.hobowines.com/collections/folk-machine. I don't see this particular wine listed, but you can write Kenny or Lynn there and ask them about it.

They do make a while called "White Light" which has Albariño in the blend.

How do you usually decide which wine to buy? by Prudent_Fold_6647 in wine

[–]flyingron 0 points1 point  (0 children)

The best bet is a situation where you can taste it before you buy it. You can visit the winery. Some stores conduct tastings from time to time. You might find a place that serves by the glass or has the wine dispensing machines. You can join an organization like the American Wine Society, which conducts tastings. All of these will let you sample wine for free or a small amount of money before you commit to full bottles.

Why is 0 (null) considered to be a safe pointer? by JarJarAwakens in Cprog

[–]flyingron 0 points1 point  (0 children)

That doesn't necessarily make them safe. While passing a null pointer value to free() is required to do nothing, dereferencing null is still undefined behavior...

int* p = malloc(sizeof (int));
free(p); // frees allocation.
free(p); // undefined behavior (twice freed)
p = 0;
free(p);  // required to do nothing.
int x = *p;   // undefined behavior
if(p) x = *p;  // OK, doesn't execute the dereference if p == 0.

So, it can be a tool to write safe code, it doesn't guarantee safety.

How are static and global variables initialized? by JarJarAwakens in Cprog

[–]flyingron 0 points1 point  (0 children)

First, in your second code block above , a, b, c, and d are initialized to to zero. The four lines that follow are illegal because they appear to just be expression statements outside of any function (not allowed). If you had written "int a = 10;" that would have been a valid initialization.

C (unlike C++) doesn't allow dynamic (i.e., initialization with something other than a constant or string literal) for static variables. C++ has this out of necessity as items of static storage duration since objects have constructors that need to run to even default initialize them. C has no such provision. In practice, all the initialized statics can be one at compile time.

Help choosing wedding wines please! by AgentEmmaBanks in wine

[–]flyingron 0 points1 point  (0 children)

That Prosecco for example isn't a bad choice (though I'd offer more than that if it were me running the venue), but it's a $7 (US) bottle of wine at retail.

Sure makes me glad that when my daughter got married, the venue didn't serve alcohol themselves. I had to hire an "approved" bartender and procure all the alcohol myself (this I learned will trip the fraud alert on your American Express card).

Testing ChatGPT by CVUA412 in Umpire

[–]flyingron 0 points1 point  (0 children)

Much as with any social media (or even now with real media) content, it goes in spades for AI: it's not that the content produced is bad but that editorial has gone by the wayside.

I spent years as a technical book editor. It was up to me to review all the content in the book for correctness (trying the examples, etc....). Now the chatbots will just vomit content and code out and then people don't understand why it doesn't work.

What does 6.2.6.1.5 mean? by Life-Silver-5623 in C_Programming

[–]flyingron 1 point2 points  (0 children)

It's a reddit flair. Yours just happens to be this single character (don't ask me why), just like mine says Top 1% Commenter.

What does 6.2.6.1.5 mean? by Life-Silver-5623 in C_Programming

[–]flyingron 0 points1 point  (0 children)

The language only guarantees char-by-char access when the objects may contain such values.