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 CPlus
| Type | On... | Excerpt | Status | Date |
|---|---|---|---|---|
| Edit | Post #290645 |
Post edited: Improved Formatting |
— | over 2 years ago |
| Suggested Edit | Post #290645 |
Suggested edit: Improved Formatting (more) |
helpful | over 2 years ago |
| Comment | Post #281518 |
Usually I use `memcpy()` if the length of the string is already known. This way the function does not need to constantly check for a null terminator. (more) |
— | over 2 years ago |
| Edit | Post #291230 | Initial revision | — | over 2 years ago |
| Question | — |
Can I access an array element from a pointer to an object contiguous with but outside the array? C prohibits accessing an array out of bounds even if measures were taken to ensure that what should lie outside those bounds were known: ``` struct MyStruct { int x[2]; int y, z; }; staticassert(sizeof(MyStruct) == sizeof(int[4]), "Unexpected Padding"); struct MyStruct s; ``` In ... (more) |
— | over 2 years ago |
