Skip to content

Commit

Permalink
test for "static const char[]" global type
Browse files Browse the repository at this point in the history
  • Loading branch information
wlav committed Oct 14, 2017
1 parent deca21a commit 2544154
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions test/advancedcpp.h
Original file line number Diff line number Diff line change
Expand Up @@ -273,6 +273,7 @@ bool operator!=( const some_comparable& c1, const some_comparable& c2 );
extern double my_global_double; // a couple of globals for access testing
extern double my_global_array[500];
extern double* my_global_ptr;
static const char my_global_string[] = "aap " " noot " " mies";

//===========================================================================
class some_class_with_data { // for life-line and identity testing
Expand Down
1 change: 1 addition & 0 deletions test/test_advancedcpp.py
Original file line number Diff line number Diff line change
Expand Up @@ -639,6 +639,7 @@ def test21_access_to_global_variables(self):

assert cppyy.gbl.my_global_double == 12.
assert len(cppyy.gbl.my_global_array) == 500
assert cppyy.gbl.my_global_string == "aap noot mies"
# TODO: currently fails b/c double** not understood as &double*
#assert cppyy.gbl.my_global_ptr[0] == 1234.

0 comments on commit 2544154

Please sign in to comment.