Welcome to Software Development on Codidact!
Will you help us build our independent community of developers helping developers? We're small and trying to grow. We welcome questions about all aspects of software development, from design to code to QA and more. Got questions? Got answers? Got code you'd like someone to review? Please join us.
Activity for GrantMoyerâ€
Type | On... | Excerpt | Status | Date |
---|---|---|---|---|
Edit | Post #289690 | Initial revision | — | 8 months ago |
Answer | — |
A: How do I customize merge behavior for a shared git repo? Frame challenge, the "bubbles" aren't useless First off, I'll challenge the premise of the question: the "merge bubbles" are not useless, because they represent meaningful development history. In particular, given the toplogy below: ```text A -- B -- C -- H master (hook declined) error: fail... (more) |
— | 8 months ago |
Edit | Post #289658 | Initial revision | — | 8 months ago |
Answer | — |
A: `git submodule foreach git pull` in parallel Git can't do this natively, but you can use git in combination with another command, such as GNU xargs First of all, fetching many repos in parallel is likely not worth it. Git fetch is likely to be limited by network speed or drive IO speed, not single core processing speed. Multiple instances of... (more) |
— | 8 months ago |
Comment | Post #288247 |
@alx My understanding is that the object at a memory address is whatever object was initially created there, regardless of whatever type a pointer to that address seems to be. For example, if you create an `int n`, it doesn't matter if you cast it like `float* a = (float*) &n`, the value pointed to b... (more) |
— | 8 months ago |
Comment | Post #288254 |
"if a union contains several structures that share a common initial sequence (see below), and if the union object currently contains one of these structures, it is permitted to inspect the common initial part of *any of them*" The way I read it, *any of them* is *any of the union members*, not *any s... (more) |
— | 11 months ago |
Edit | Post #288247 |
Post edited: grammar |
— | 11 months ago |
Edit | Post #288247 |
Post edited: typo |
— | 11 months ago |
Edit | Post #288247 |
Post edited: typo |
— | 11 months ago |
Edit | Post #288247 |
Post edited: simplify flow |
— | 11 months ago |
Edit | Post #288247 |
Post edited: comment on number of bytes copied |
— | 11 months ago |
Edit | Post #288247 |
Post edited: Add note about GCC behavior |
— | 11 months ago |
Edit | Post #288247 |
Post edited: |
— | 11 months ago |
Edit | Post #288247 |
Post edited: |
— | 11 months ago |
Edit | Post #288247 | Initial revision | — | 11 months ago |
Answer | — |
A: Storing more bytes than a union member has, but less than the union size, with memcpy(3) Reading from a union member who's size is larger than that of the last written member is explicitly allowed since C99, but the value of the extra bytes is unspecified. From the cppreference page on C unions: > If the size of the new type is larger than the size of the last-written type, the conten... (more) |
— | 11 months ago |