Skip to content

Commit

Permalink
Merge pull request #1034 from DLR-AMR/remove-bool-from-c-files
Browse files Browse the repository at this point in the history
  • Loading branch information
holke authored Apr 15, 2024
2 parents bd22617 + 96252e2 commit 3e653f9
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 8 deletions.
4 changes: 2 additions & 2 deletions src/t8_cmesh.h
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ t8_cmesh_is_committed (const t8_cmesh_t cmesh);
* \param [in] cmesh This cmesh is examined.
* \return True if the geometry of the cmesh is valid.
*/
bool
int
t8_cmesh_validate_geometry (const t8_cmesh_t cmesh);

/** After a cmesh is committed, check whether all trees in a cmesh do have positive volume.
Expand All @@ -107,7 +107,7 @@ t8_cmesh_validate_geometry (const t8_cmesh_t cmesh);
* was called, do have positive geometric volume.
* False otherwise.
*/
bool
int
t8_cmesh_no_negative_volume (t8_cmesh_t cmesh);
#endif

Expand Down
4 changes: 2 additions & 2 deletions src/t8_cmesh/t8_cmesh.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ t8_cmesh_is_committed (const t8_cmesh_t cmesh)
}

#ifdef T8_ENABLE_DEBUG
bool
int
t8_cmesh_validate_geometry (const t8_cmesh_t cmesh)
{
/* Geometry handler is not constructed yet */
Expand Down Expand Up @@ -532,7 +532,7 @@ t8_cmesh_tree_vertices_negative_volume (const t8_eclass_t eclass, const double *
* Returns true if all trees have positive volume. Returns also true if no geometries are
* registered yet, since the volume computation depends on the used geometry.
*/
bool
int
t8_cmesh_no_negative_volume (t8_cmesh_t cmesh)
{
bool res = false;
Expand Down
2 changes: 1 addition & 1 deletion src/t8_geometry/t8_geometry.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ t8_geometry_get_type (t8_cmesh_t cmesh, t8_gloidx_t gtreeid)
return cmesh->geometry_handler->get_tree_geometry_type (cmesh, gtreeid);
}

bool
int
t8_geometry_tree_negative_volume (const t8_cmesh_t cmesh, const t8_gloidx_t gtreeid)
{
return cmesh->geometry_handler->tree_negative_volume (cmesh, gtreeid);
Expand Down
3 changes: 1 addition & 2 deletions src/t8_geometry/t8_geometry.h
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,6 @@

#include <t8.h>
#include <t8_refcount.h>
#include <stdbool.h>

/** This enumeration contains all possible geometries. */
typedef enum t8_geometry_type {
Expand Down Expand Up @@ -109,7 +108,7 @@ t8_geometry_get_type (t8_cmesh_t cmesh, t8_gloidx_t gtreeid);
* \param[in] gtreeid The global id of the tree
* \return True if the tree with id \ref gtreeid has a negative volume. False otherwise.
*/
bool
int
t8_geometry_tree_negative_volume (const t8_cmesh_t cmesh, const t8_gloidx_t gtreeid);

T8_EXTERN_C_END ();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ typedef void (*t8_geom_load_tree_data_fn) (t8_cmesh_t cmesh, t8_gloidx_t gtreeid
/**
* Definition for the negative volume function.
*/
typedef bool (*t8_geom_tree_negative_volume_fn) ();
typedef int (*t8_geom_tree_negative_volume_fn) ();

T8_EXTERN_C_BEGIN ();

Expand Down

0 comments on commit 3e653f9

Please sign in to comment.