Skip to content

Fix ascii reallocation in Union_mesh#2532

Merged
willend merged 5 commits into
mccode-dev:mainfrom
mads-bertelsen:mesh_fix
Jun 29, 2026
Merged

Fix ascii reallocation in Union_mesh#2532
willend merged 5 commits into
mccode-dev:mainfrom
mads-bertelsen:mesh_fix

Conversation

@mads-bertelsen

@mads-bertelsen mads-bertelsen commented Jun 29, 2026

Copy link
Copy Markdown
Contributor

Free-form text area

Please describe what your PR is adding in terms of features or bugfixes:
Fixed small error that exit if reallocation of memory in Union_mesh is successful, rather than exiting if it fails.


Development OS / boundary conditions

Please describe what OS you developed and tested your additions on, and if any special dependencies are required:
OS X 14.8.7


PR Checklist for contributing to McStas/McXtrace

For a coherent and useful contribution to McStas/McXtrace, please fill in relevant parts of the checklist:

  • My contribution includes patches to an existing component file

    • I have used the mcdoc utility and rendered a reasonable documentation page for the component (please attach as screenshot in comments!)
    • I have ensured that basic use of the component is OK (e.g. an instrument using it compiles?)
    • I have used the mctest utility to test one or more instruments making use of the component (please attach mcviewtest report as screenshot in comments)
    • I have used the mccode-clangformat tool to apply the standard McCode component indentation scheme
    • I have used the mcrun --c-lint "linter" and followed advice to remove most / all warnings that are raised

Fixed small error that exit if reallocation of memory in Union_mesh is successful, rather than exiting if it fails.
@mads-bertelsen mads-bertelsen marked this pull request as draft June 29, 2026 09:06
@mads-bertelsen

Copy link
Copy Markdown
Contributor Author
Geometry_test   :   7.94
Many_meshes     :   5.97
Test_mesh_boxes :   5.43

Running tests / getting status...
Geometry_test    :   Display OK (4s)
Geometry_test    :  11.35    [val: 46.7433 / 47.5 = 98 %]
Geometry_test_2  :  10.92    [val: 46.7433 / 47.5 = 98 %]
Many_meshes      :   Display OK (2s)
Many_meshes      :  14.72    [val: 4.67285e-06 / 4.63384e-06 = 101 %]
Test_mesh_boxes  :   Display OK (2s)
Test_mesh_boxes  :   3.62    [val: 10.7755 / 10.7752 = 100 %]
======================================
Overall test result:
SUCCESS

@mads-bertelsen mads-bertelsen marked this pull request as ready for review June 29, 2026 12:06
@willend

willend commented Jun 29, 2026

Copy link
Copy Markdown
Contributor

Nice, looks good, merging.

@willend willend merged commit aa78e4f into mccode-dev:main Jun 29, 2026
10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants