]> granicus.if.org Git - graphviz/log
graphviz
2 years agouse C99 bools to set 'onstack'
Matthew Fernandez [Sun, 16 Jan 2022 19:30:36 +0000 (11:30 -0800)]
use C99 bools to set 'onstack'

2 years agoremove comparisons against 'TRUE' literal
Matthew Fernandez [Sun, 16 Jan 2022 19:20:35 +0000 (11:20 -0800)]
remove comparisons against 'TRUE' literal

The variables involved here are all booleans or used exclusively as booleans.

2 years agoremove comparisons against 'FALSE' literal
Matthew Fernandez [Sun, 16 Jan 2022 19:14:55 +0000 (11:14 -0800)]
remove comparisons against 'FALSE' literal

2 years agoMerge branch 'smattr/1C578045-99DC-414C-BF4A-C517F2EC40B8' into 'main'
Matthew Fernandez [Thu, 20 Jan 2022 02:09:29 +0000 (02:09 +0000)]
Merge branch 'smattr/1C578045-99DC-414C-BF4A-C517F2EC40B8' into 'main'

mingle: replace some `unique_ptr` with `vector`

See merge request graphviz/graphviz!2412

2 years agomingle bundle: replace a 'unique_ptr' with a 'vector'
Matthew Fernandez [Sun, 16 Jan 2022 22:04:09 +0000 (14:04 -0800)]
mingle bundle: replace a 'unique_ptr' with a 'vector'

Similar to the prior commit, when the `std::unique_ptr` usage was added here in
176c8a163a951a2b801956ed4a00da05603e3a06, I was incorrectly too focused on
preserving the previous property of this being a heap-allocated array. This is
not necessary, and using a `std::vector` instead allows more flexibility. E.g.
depending on the `std::vector` implementation, it could choose to allocate this
array on the stack instead of the heap.

2 years agomingle genBundleColors: replace a 'unique_ptr' with a 'vector'
Matthew Fernandez [Sun, 16 Jan 2022 22:00:51 +0000 (14:00 -0800)]
mingle genBundleColors: replace a 'unique_ptr' with a 'vector'

When the `std::unique_ptr` usage was added here in
869891f9c87b326ddef4de461b92de98ec647b82, I was incorrectly too focused on
preserving the previous property of this being a heap-allocated array. This is
not necessary, and using a `std::vector` instead allows more flexibility. E.g.
depending on the `std::vector` implementation, it could choose to allocate this
array on the stack instead of the heap.

2 years agoMerge branch 'smattr/AC433706-8F92-4102-816C-75433E82B00D' into 'main'
Matthew Fernandez [Wed, 19 Jan 2022 17:17:53 +0000 (17:17 +0000)]
Merge branch 'smattr/AC433706-8F92-4102-816C-75433E82B00D' into 'main'

expr: fix misinterpretation of shifts

Closes #2103

See merge request graphviz/graphviz!2409

2 years agoexpr: fix misinterpretation of shifts
Matthew Fernandez [Sun, 16 Jan 2022 18:47:37 +0000 (10:47 -0800)]
expr: fix misinterpretation of shifts

It is fairly clear from the surrounding code that these instances were writing
to the wrong destination and, in some cases, reading from the wrong sources. The
effect of this bug was a little slippery as the underlying storage is a union
with `integer` and `floating` occupying the same storage, so this change does
not alter which bytes are stored to. Additionally users rarely left or right
shift within GVPR scripts, so it is unlikely this affected any real world code.

Gitlab: Fixes #2103

2 years agoexpr: remove legacy IBM compiler work around
Matthew Fernandez [Sun, 16 Jan 2022 18:37:48 +0000 (10:37 -0800)]
expr: remove legacy IBM compiler work around

Despite dredging the commit log, comp.lang, and Stack Overflow, I have been
unable to determine what these comments refer to. They read to me like working
around a register allocator bug. AFAIK every production compiler from the last
decade has been capable of these kind of one-line shifts without work arounds.

Gitlab: #2103

2 years agoMerge branch 'smattr/D5729AAE-102F-4B2D-8A3A-8E02AD0D9A7A' into 'main'
Matthew Fernandez [Wed, 19 Jan 2022 16:16:12 +0000 (16:16 +0000)]
Merge branch 'smattr/D5729AAE-102F-4B2D-8A3A-8E02AD0D9A7A' into 'main'

reformat example code

See merge request graphviz/graphviz!2408

2 years agoMerge branch 'add-missing-changlog-entry-for-fixed-lneato' into 'main'
Magnus Jacobsson [Wed, 19 Jan 2022 07:46:21 +0000 (07:46 +0000)]
Merge branch 'add-missing-changlog-entry-for-fixed-lneato' into 'main'

add a CHANGELOG entry for lneato fix

See merge request graphviz/graphviz!2415

2 years agoadd a CHANGELOG entry for lneato fix
Magnus Jacobsson [Tue, 18 Jan 2022 22:02:17 +0000 (23:02 +0100)]
add a CHANGELOG entry for lneato fix

2 years agodot.demo/dot.c: [nfc] align with C99 style and clang-format
Matthew Fernandez [Sun, 16 Jan 2022 18:19:35 +0000 (10:19 -0800)]
dot.demo/dot.c: [nfc] align with C99 style and clang-format

2 years agodot.demo/demo.c: [nfc] align with C99 style and clang-format
Matthew Fernandez [Sun, 16 Jan 2022 18:18:18 +0000 (10:18 -0800)]
dot.demo/demo.c: [nfc] align with C99 style and clang-format

2 years agodot.demo/simple.c: [nfc] align with C99 style and clang-format
Matthew Fernandez [Sun, 16 Jan 2022 18:16:16 +0000 (10:16 -0800)]
dot.demo/simple.c: [nfc] align with C99 style and clang-format

2 years agodot.demo/example.c: [nfc] align with C99 style and clang-format
Matthew Fernandez [Sun, 16 Jan 2022 18:15:01 +0000 (10:15 -0800)]
dot.demo/example.c: [nfc] align with C99 style and clang-format

2 years agodot.demo/neatopack.c:[nfc] align with C99 style and clang-format
Matthew Fernandez [Sun, 16 Jan 2022 18:11:44 +0000 (10:11 -0800)]
dot.demo/neatopack.c:[nfc]  align with C99 style and clang-format

2 years agoMerge branch 'smattr/97832B69-55F8-4C57-9704-188684569B12' into 'main'
Matthew Fernandez [Wed, 19 Jan 2022 05:43:01 +0000 (05:43 +0000)]
Merge branch 'smattr/97832B69-55F8-4C57-9704-188684569B12' into 'main'

remove Lefty from CI and portable source tarball

See merge request graphviz/graphviz!2413

2 years agoremove Lefty dependencies from CI Docker images
Matthew Fernandez [Mon, 17 Jan 2022 04:49:11 +0000 (20:49 -0800)]
remove Lefty dependencies from CI Docker images

As of the prior commit, these are no longer used.

2 years agono longer enable Lefty in Autotools builds
Matthew Fernandez [Mon, 17 Jan 2022 04:43:14 +0000 (20:43 -0800)]
no longer enable Lefty in Autotools builds

1a4ad00b59cc1e1e9302fcbd1a205495ee59cab5 made the Autotools build system default
to disabling Lefty as a step towards its deprecation. As three months have
passed, the present commit takes the next step and removes Lefty support from
the portable tarball and stops building it in CI. Users who still want Lefty can
build from source and re-enable it. If we hear from no such users in the next
three months, build system support for Lefty will be removed altogether. If a
further three months go by with no complaints, Lefty will then be deleted from
the repository.

2 years agoremove Lefty test cases
Matthew Fernandez [Mon, 17 Jan 2022 04:40:37 +0000 (20:40 -0800)]
remove Lefty test cases

The Lefty tool is deprecated and planned to be removed.
1a4ad00b59cc1e1e9302fcbd1a205495ee59cab5 toggled it to default to disabled in
the Autotools build system. The present change is a preparatory commit for
dropping explicit re-enabling of it in CI, allowing it to no longer be compiled
in CI.

2 years agoMerge branch 'smattr/BC8175D4-61E0-42FB-B7FA-EFC605CC9333' into 'main'
Matthew Fernandez [Tue, 18 Jan 2022 16:40:27 +0000 (16:40 +0000)]
Merge branch 'smattr/BC8175D4-61E0-42FB-B7FA-EFC605CC9333' into 'main'

get_cycle_centroid: undo caching or cycle list

See merge request graphviz/graphviz!2414

2 years agoget_cycle_centroid: undo caching of 'cycle' list
Matthew Fernandez [Mon, 17 Jan 2022 16:09:11 +0000 (08:09 -0800)]
get_cycle_centroid: undo caching of 'cycle' list

This function attempted to save time by caching the results of a graph cycle
search and then reusing them in a future call. The logic used for this caching
is invalid. It compares graph pointers to see if it is operating on the same
graph as last time, but this can return a false positive if the previous graph
has been deallocated and a new (unrelated) graph has been allocated at the same
address.

This logic would eventually have to be unwound or adjusted in order to support
multithreading in this code too.

It is possible this is the root cause of the issue described in #2162, though I
was never able to reproduce that issue.

2 years agoMerge branch 'smattr/884E30F6-80F8-47C7-B083-88BC1718A1F5' into 'main'
Matthew Fernandez [Tue, 18 Jan 2022 07:22:45 +0000 (07:22 +0000)]
Merge branch 'smattr/884E30F6-80F8-47C7-B083-88BC1718A1F5' into 'main'

agglomerative_ink_bundling_internal: remove disabled code

See merge request graphviz/graphviz!2411

2 years agoagglomerative_ink_bundling_internal: remove disabled code
Matthew Fernandez [Sun, 16 Jan 2022 21:57:00 +0000 (13:57 -0800)]
agglomerative_ink_bundling_internal: remove disabled code

This code has been a no-op since its first addition in
0cd264937e210404c56c195b9b74749e41ffa332. Anything ANDed with `FALSE` is
`FALSE`.

2 years agoMerge branch 'fix-lneato-on-windows' into 'main'
Magnus Jacobsson [Mon, 17 Jan 2022 17:35:34 +0000 (17:35 +0000)]
Merge branch 'fix-lneato-on-windows' into 'main'

Fix flaky lneato usage on Windows

Closes #1934

See merge request graphviz/graphviz!2407

2 years agotest_tools: remove now obsolete workaround for flaky lneato usage
Magnus Jacobsson [Sun, 16 Jan 2022 12:24:46 +0000 (13:24 +0100)]
test_tools: remove now obsolete workaround for flaky lneato usage

2 years agolneato: Windows: correct argument interpretation with respect to unicode
Magnus Jacobsson [Sun, 16 Jan 2022 09:52:23 +0000 (10:52 +0100)]
lneato: Windows: correct argument interpretation with respect to unicode

Change from WinMain to wWinMain to handle unicode correctly and avoid
the flakiness of the test_tools test.

Fixes https://gitlab.com/graphviz/graphviz/-/issues/1934.

The culprit was probably this warning which now is removed:

C:\GitLab-Runner\builds\magjac\graphviz\cmd\lneato\mswin32\lneato.c(46,40): warning C4133: 'function': incompatible types - from 'LPSTR' to 'LPCWSTR' [C:\GitLab-Runner\builds\magjac\graphviz\cmd\lneato\lneato.vcxproj]

LPSTR is a char* and LPCWSTR is a const wchar_t*. The former points to
an array of 8-bit characters, while the latter points to an array of
16-bit characters. See
https://docs.microsoft.com/en-us/windows/win32/learnwin32/working-with-strings.

In order for the argument interpretation to work correctly after this
change, another change was necessary. The type of the argv variable is
LPWSTR which is a wchar_t* so we must use wcscmp and wide-character
literal string to get a correct 16-bit unicode character comparison.

Removes this warning:

C:\GitLab-Runner\builds\magjac\graphviz\cmd\lneato\mswin32\lneato.c(47,36): warning C4133: 'function': incompatible types - from 'LPWSTR' to 'const char *' [C:\GitLab-Runner\builds\magjac\graphviz\cmd\lneato\lneato.vcxproj]

Although not necessary, this commit also renames the lpCmdLine
argument to pCmdLine in order to match the naming in the wWinMain
signature.

This commit also removes the expectation that lneato should fail at
least one time out of 100 in the test_tools test. The actual
workaround for the flakiness will be removed in the next commit in
this series.

2 years agolneato: Windows: correct argument types to WinMain
Magnus Jacobsson [Sat, 15 Jan 2022 16:38:24 +0000 (17:38 +0100)]
lneato: Windows: correct argument types to WinMain

Fixes these warnings:

C:\GitLab-Runner\builds\magjac\graphviz\cmd\lneato\mswin32\lneato.c(27,28): warning C4028: formal parameter 1 different from declaration [C:\GitLab-Runner\builds\magjac\graphviz\cmd\lneato\lneato.vcxproj]
C:\GitLab-Runner\builds\magjac\graphviz\cmd\lneato\mswin32\lneato.c(27,46): warning C4028: formal parameter 2 different from declaration [C:\GitLab-Runner\builds\magjac\graphviz\cmd\lneato\lneato.vcxproj]

See
https://docs.microsoft.com/en-us/windows/win32/api/winbase/nf-winbase-winmain.

2 years agolneato: Windows: replace obsolete PASCAL declaration with WINAPI
Magnus Jacobsson [Sat, 15 Jan 2022 16:35:11 +0000 (17:35 +0100)]
lneato: Windows: replace obsolete PASCAL declaration with WINAPI

See
https://docs.microsoft.com/en-us/cpp/cpp/obsolete-calling-conventions?view=msvc-170.

2 years agoMerge branch 'smattr/34de5d89-7e39-49ff-857a-325fd4169853' into 'main'
Matthew Fernandez [Sun, 16 Jan 2022 20:00:25 +0000 (20:00 +0000)]
Merge branch 'smattr/34de5d89-7e39-49ff-857a-325fd4169853' into 'main'

move the remainder of mingle into C++

Closes #2154

See merge request graphviz/graphviz!2405

2 years agonearest_neighbor_graph_ann: use a reference for 'nz0' instead of pointer
Matthew Fernandez [Sat, 15 Jan 2022 22:18:48 +0000 (14:18 -0800)]
nearest_neighbor_graph_ann: use a reference for 'nz0' instead of pointer

This parameter is non-nullable, so we can make the type signature reflect that.

2 years agoagglomerative_ink_bundling_internal: remove 'xx' manual memory management
Matthew Fernandez [Sat, 15 Jan 2022 22:13:52 +0000 (14:13 -0800)]
agglomerative_ink_bundling_internal: remove 'xx' manual memory management

2 years agoAgglomerative_Ink_Bundling: remove 'inks' manual memory management
Matthew Fernandez [Sat, 15 Jan 2022 22:11:29 +0000 (14:11 -0800)]
Agglomerative_Ink_Bundling: remove 'inks' manual memory management

2 years agoAgglomerative_Ink_Bundling: remove unused 'prev' pointers
Matthew Fernandez [Sat, 15 Jan 2022 22:04:37 +0000 (14:04 -0800)]
Agglomerative_Ink_Bundling: remove unused 'prev' pointers

This struct was used as a node in a doubly-linked list. But the back pointers
were never used. This commit simplifies it into a singly-linked-list.

2 years agolib/mingle headers: drop 'extern "C"'
Matthew Fernandez [Sat, 15 Jan 2022 21:41:51 +0000 (13:41 -0800)]
lib/mingle headers: drop 'extern "C"'

These headers are only used by C++ code, so they no longer need to fallback to C
linkage.

Gitlab: #2154

2 years agoAgglomerative_Ink_Bundling_new: remove 'pick' manual memory management
Matthew Fernandez [Sat, 15 Jan 2022 21:34:22 +0000 (13:34 -0800)]
Agglomerative_Ink_Bundling_new: remove 'pick' manual memory management

2 years agoAgglomerative_Ink_Bundling_establish: remove unused 'mask'
Matthew Fernandez [Sat, 15 Jan 2022 21:32:45 +0000 (13:32 -0800)]
Agglomerative_Ink_Bundling_establish: remove unused 'mask'

It is unclear to me what the purpose of this local was intended to be.
Furthermore it was being mis-allocated as if it were an array of doubles, not
ints.

2 years agoAgglomerative_Ink_Bundling_establish: remove 'matching' manual memory management
Matthew Fernandez [Sat, 15 Jan 2022 21:30:52 +0000 (13:30 -0800)]
Agglomerative_Ink_Bundling_establish: remove 'matching' manual memory management

Gitlab: #2154

2 years agoremove now unused 'Vector_*' API
Matthew Fernandez [Sat, 15 Jan 2022 21:27:46 +0000 (13:27 -0800)]
remove now unused 'Vector_*' API

2 years agoAgglomerative_Ink_Bundling_establish: replace 'cedges' with a 'std::vector'
Matthew Fernandez [Sat, 15 Jan 2022 21:24:20 +0000 (13:24 -0800)]
Agglomerative_Ink_Bundling_establish: replace 'cedges' with a 'std::vector'

This simplifies the code as well as making it significantly easier for humans
and compilers to understand what is going on here.

2 years agoagglomerative_bundling.c: move into C++
Matthew Fernandez [Sat, 15 Jan 2022 21:11:09 +0000 (13:11 -0800)]
agglomerative_bundling.c: move into C++

This completes moving all of lib/mingle into C++. Closes #2154.

2 years agoagglomerative_bundling.c: explicitly cast the results of 'realloc'
Matthew Fernandez [Sat, 15 Jan 2022 21:12:31 +0000 (13:12 -0800)]
agglomerative_bundling.c: explicitly cast the results of 'realloc'

This has no effect in C, but an upcoming change will move this code to C++ where
this is required.

Gitlab: #2154

2 years agoagglomerative_bundling.c: explicitly cast the results of 'malloc'
Matthew Fernandez [Sat, 15 Jan 2022 21:09:07 +0000 (13:09 -0800)]
agglomerative_bundling.c: explicitly cast the results of 'malloc'

This has no effect in C, but an upcoming change will move this code to C++ where
this is required.

Gitlab: #2154

2 years agoMerge branch 'smattr/4d675265-10af-4846-b248-df57d7ea3ae2' into 'main'
Matthew Fernandez [Sun, 16 Jan 2022 18:46:18 +0000 (18:46 +0000)]
Merge branch 'smattr/4d675265-10af-4846-b248-df57d7ea3ae2' into 'main'

more boolean → bool modernization

See merge request graphviz/graphviz!2406

2 years agoAPI BREAK: remove now-unused 'boolean' type
Matthew Fernandez [Sun, 16 Jan 2022 00:43:17 +0000 (16:43 -0800)]
API BREAK: remove now-unused 'boolean' type

2 years agoAPI BREAK: use C99 bools for booleans in 'GVC_common_s'
Matthew Fernandez [Sun, 16 Jan 2022 00:37:40 +0000 (16:37 -0800)]
API BREAK: use C99 bools for booleans in 'GVC_common_s'

2 years agoAPI BREAK: return a C99 bool from 'gvusershape_file_access'
Matthew Fernandez [Sun, 16 Jan 2022 00:31:42 +0000 (16:31 -0800)]
API BREAK: return a C99 bool from 'gvusershape_file_access'

2 years agoAPI BREAK: use a C99 bool for 'pccomps' output parameter
Matthew Fernandez [Sun, 16 Jan 2022 00:29:57 +0000 (16:29 -0800)]
API BREAK: use a C99 bool for 'pccomps' output parameter

2 years agoAPI BREAK: use a C99 bool array for 'pack_info.fixed'
Matthew Fernandez [Sun, 16 Jan 2022 00:27:42 +0000 (16:27 -0800)]
API BREAK: use a C99 bool array for 'pack_info.fixed'

2 years agoAPI BREAK: return a C99 bool from 'gvtextlayout_engine_t.textlayout'
Matthew Fernandez [Sun, 16 Jan 2022 00:16:40 +0000 (16:16 -0800)]
API BREAK: return a C99 bool from 'gvtextlayout_engine_t.textlayout'

2 years agoAPI BREAK: take a C99 bool in 'gvloadimage_engine_t.loadimage'
Matthew Fernandez [Sun, 16 Jan 2022 00:08:12 +0000 (16:08 -0800)]
API BREAK: take a C99 bool in 'gvloadimage_engine_t.loadimage'

2 years agoAPI BREAK: use a C99 bool for other 'GVJ_t' boolean fields
Matthew Fernandez [Sat, 15 Jan 2022 23:58:15 +0000 (15:58 -0800)]
API BREAK: use a C99 bool for other 'GVJ_t' boolean fields

2 years agoAPI BREAK: use a C99 bool for 'GVJ_t.external_context'
Matthew Fernandez [Sat, 15 Jan 2022 23:45:31 +0000 (15:45 -0800)]
API BREAK: use a C99 bool for 'GVJ_t.external_context'

2 years agoAPI BREAK: use a C99 bool for 'GVJ_t.device_sets_dpi'
Matthew Fernandez [Sat, 15 Jan 2022 23:42:33 +0000 (15:42 -0800)]
API BREAK: use a C99 bool for 'GVJ_t.device_sets_dpi'

2 years agoAPI BREAK: use a C99 bool for 'usershape_t.nocache'
Matthew Fernandez [Sat, 15 Jan 2022 23:39:39 +0000 (15:39 -0800)]
API BREAK: use a C99 bool for 'usershape_t.nocache'

2 years agoAPI BREAK: use a C99 bool for 'usershape_t.must_inline'
Matthew Fernandez [Sat, 15 Jan 2022 23:38:07 +0000 (15:38 -0800)]
API BREAK: use a C99 bool for 'usershape_t.must_inline'

2 years agoAPI BREAK: use unsigned types for 1-bit fields of 'obj_state_s'
Matthew Fernandez [Sat, 15 Jan 2022 23:34:23 +0000 (15:34 -0800)]
API BREAK: use unsigned types for 1-bit fields of 'obj_state_s'

This has little impact (the bit encoding of these fields is identical), but it
suppresses numerous -Wconversion warnings from the compiler, worried that an
implicit conversion from `1` to `-1` was unintended.

2 years agoAPI BREAK: use a C99 bool for 'Agedgeinfo_t.conc_opp_flag'
Matthew Fernandez [Sat, 15 Jan 2022 23:27:51 +0000 (15:27 -0800)]
API BREAK: use a C99 bool for 'Agedgeinfo_t.conc_opp_flag'

2 years agoAPI BREAK: use a C99 bool for 'Agnodeinfo_t.has_port'
Matthew Fernandez [Sat, 15 Jan 2022 23:26:06 +0000 (15:26 -0800)]
API BREAK: use a C99 bool for 'Agnodeinfo_t.has_port'

2 years agoAPI BREAK: use a C99 bool for 'Agnodeinfo_t.clustnode'
Matthew Fernandez [Sat, 15 Jan 2022 23:24:22 +0000 (15:24 -0800)]
API BREAK: use a C99 bool for 'Agnodeinfo_t.clustnode'

2 years agoMerge branch 'smattr/F84CFD8E-734D-47B0-A614-AD649741668A' into 'main'
Matthew Fernandez [Sun, 16 Jan 2022 02:00:55 +0000 (02:00 +0000)]
Merge branch 'smattr/F84CFD8E-734D-47B0-A614-AD649741668A' into 'main'

add test case for #1879

See merge request graphviz/graphviz!2404

2 years agoadd test case for #1879
Matthew Fernandez [Sun, 18 Apr 2021 21:40:11 +0000 (14:40 -0700)]
add test case for #1879

Unfortunately we cannot xfail this test with `strict=True` because this test
passes or fails across various different platforms with no discernible pattern
to me. Results from the current commit:

  * pass: CentOS 7, CentOS 7 CMake, Fedora 35, macOS, macOS CMake, Ubuntu 20.04,
          MinGW 32 CMake, MinGW 64 CMake
  * fail: Fedora 34, Ubuntu 18.04, Ubuntu 18.04 CMake, Ubuntu 21.04,
          Ubuntu 21.04 CMake, Ubuntu 21.10, Ubuntu 21.10 CMake,
          Windows all debug builds

2 years agoMerge branch 'smattr/af7ac83f-22ac-4fff-b0d2-b7136bfc5813' into 'main'
Matthew Fernandez [Sun, 16 Jan 2022 00:09:51 +0000 (00:09 +0000)]
Merge branch 'smattr/af7ac83f-22ac-4fff-b0d2-b7136bfc5813' into 'main'

more boolean → bool modernization

See merge request graphviz/graphviz!2403

2 years agoAPI BREAK: use a C99 bool for 'Agraphinfo.exact_ranksep'
Matthew Fernandez [Sat, 15 Jan 2022 19:00:32 +0000 (11:00 -0800)]
API BREAK: use a C99 bool for 'Agraphinfo.exact_ranksep'

2 years agoAPI BREAK: use a C99 bool for 'Agraphinfo.expanded'
Matthew Fernandez [Sat, 15 Jan 2022 18:59:15 +0000 (10:59 -0800)]
API BREAK: use a C99 bool for 'Agraphinfo.expanded'

2 years agoAPI BREAK: use a C99 bool for 'Agraphinfo.has_sinkrank'
Matthew Fernandez [Sat, 15 Jan 2022 18:57:58 +0000 (10:57 -0800)]
API BREAK: use a C99 bool for 'Agraphinfo.has_sinkrank'

2 years agoAPI BREAK: use a C99 bool for 'Agraphinfo.has_sourcerank'
Matthew Fernandez [Sat, 15 Jan 2022 18:56:42 +0000 (10:56 -0800)]
API BREAK: use a C99 bool for 'Agraphinfo.has_sourcerank'

2 years agoAPI BREAK: use a C99 bool for 'Agraphinfo.has_flat_edges'
Matthew Fernandez [Sat, 15 Jan 2022 18:55:26 +0000 (10:55 -0800)]
API BREAK: use a C99 bool for 'Agraphinfo.has_flat_edges'

2 years agoAPI BREAK: use a C99 bool for 'Agraphinfo_t.has_images'
Matthew Fernandez [Sat, 15 Jan 2022 18:53:15 +0000 (10:53 -0800)]
API BREAK: use a C99 bool for 'Agraphinfo_t.has_images'

2 years agoAPI BREAK: use C99 bools for 'layout_t' boolean fields
Matthew Fernandez [Sat, 15 Jan 2022 18:50:01 +0000 (10:50 -0800)]
API BREAK: use C99 bools for 'layout_t' boolean fields

2 years agoAPI BREAK: use C99 bools for 'rank_t' boolean fields
Matthew Fernandez [Sat, 15 Jan 2022 18:41:34 +0000 (10:41 -0800)]
API BREAK: use C99 bools for 'rank_t' boolean fields

2 years agoAPI BREAK: use a C99 bool for 'shape_desc.usershape' instead of a boolean
Matthew Fernandez [Sat, 15 Jan 2022 18:34:08 +0000 (10:34 -0800)]
API BREAK: use a C99 bool for 'shape_desc.usershape' instead of a boolean

2 years agoAPI BREAK: use C99 bools for 'textlabel_t' fields instead of booleans
Matthew Fernandez [Sat, 15 Jan 2022 18:31:55 +0000 (10:31 -0800)]
API BREAK: use C99 bools for 'textlabel_t' fields instead of booleans

2 years agomake_label: remove unnecessary casts
Matthew Fernandez [Sat, 15 Jan 2022 18:16:51 +0000 (10:16 -0800)]
make_label: remove unnecessary casts

2 years agolefty: use a C99 bool instead of int for 'htmlflag' in 'writeattr'
Matthew Fernandez [Sat, 15 Jan 2022 18:16:27 +0000 (10:16 -0800)]
lefty: use a C99 bool instead of int for 'htmlflag' in 'writeattr'

2 years agolefty: use a C99 bool instead of int for 'innetscape'
Matthew Fernandez [Sat, 15 Jan 2022 18:16:01 +0000 (10:16 -0800)]
lefty: use a C99 bool instead of int for 'innetscape'

2 years agolefty: return a C99 bool from 'boolop' instead of an int
Matthew Fernandez [Sat, 15 Jan 2022 18:13:09 +0000 (10:13 -0800)]
lefty: return a C99 bool from 'boolop' instead of an int

2 years agolefty AIX I/O: return a C99 bool from 'boolop' instead of an int
Matthew Fernandez [Sat, 15 Jan 2022 18:11:03 +0000 (10:11 -0800)]
lefty AIX I/O: return a C99 bool from 'boolop' instead of an int

2 years agoleft: take a C99 bool in 'buildpath' instead of an int
Matthew Fernandez [Sat, 15 Jan 2022 18:07:56 +0000 (10:07 -0800)]
left: take a C99 bool in 'buildpath' instead of an int

2 years agoAPI BREAK: use C99 bools for 'port' fields instead of booleans
Matthew Fernandez [Sat, 15 Jan 2022 17:51:44 +0000 (09:51 -0800)]
API BREAK: use C99 bools for 'port' fields instead of booleans

2 years agoAPI BREAK: use a C99 bool for 'isOrtho' instead of a boolean
Matthew Fernandez [Sat, 15 Jan 2022 17:38:05 +0000 (09:38 -0800)]
API BREAK: use a C99 bool for 'isOrtho' instead of a boolean

2 years agoAPI BREAK: use a C99 bool for 'ignoreSwap' instead of a boolean
Matthew Fernandez [Sat, 15 Jan 2022 17:33:10 +0000 (09:33 -0800)]
API BREAK: use a C99 bool for 'ignoreSwap' instead of a boolean

2 years agoAPI BREAK: return a C99 bool from 'swapEnds instead of a boolean
Matthew Fernandez [Sat, 15 Jan 2022 17:27:39 +0000 (09:27 -0800)]
API BREAK: return a C99 bool from 'swapEnds instead of a boolean

2 years agoAPI BREAK: return a C99 bool from 'splineMerge' instead of a boolean
Matthew Fernandez [Sat, 15 Jan 2022 17:19:21 +0000 (09:19 -0800)]
API BREAK: return a C99 bool from 'splineMerge' instead of a boolean

2 years agoAPI BREAK: return a C99 bool from 'insidefn' instead of a boolean
Matthew Fernandez [Sat, 15 Jan 2022 17:10:03 +0000 (09:10 -0800)]
API BREAK: return a C99 bool from 'insidefn' instead of a boolean

2 years agoMerge branch 'smattr/449D4938-41BE-4359-B1B0-6C19D1570E24' into 'main'
Matthew Fernandez [Sat, 15 Jan 2022 22:27:19 +0000 (22:27 +0000)]
Merge branch 'smattr/449D4938-41BE-4359-B1B0-6C19D1570E24' into 'main'

some Python tweaks to test code

See merge request graphviz/graphviz!2398

2 years agoshell-quote commands echoed during testing
Matthew Fernandez [Tue, 11 Jan 2022 01:23:49 +0000 (17:23 -0800)]
shell-quote commands echoed during testing

It is not typical that testing paths will contain things like spaces and other
characters that require quoting. But this change goes the extra mile to make
sure these echoed commands are always copy-pastable to re-execute them.

2 years agorun_c: [nfc] factor out an array addition
Matthew Fernandez [Sat, 15 Jan 2022 20:59:54 +0000 (12:59 -0800)]
run_c: [nfc] factor out an array addition

This will make an upcoming commit clearer and more concise.

2 years agorun_c: check return code of compiled program before returning
Matthew Fernandez [Tue, 11 Jan 2022 01:05:58 +0000 (17:05 -0800)]
run_c: check return code of compiled program before returning

Every call to `run_c` was immediately checking that the compiled program
succeeded. So by moving the check inside `run_c` itself we can write more
concise test cases.

2 years agoMerge branch 'smattr/5dbb61ed-6813-47f4-918d-6a6047f05fa9' into 'main'
Matthew Fernandez [Sat, 15 Jan 2022 18:13:38 +0000 (18:13 +0000)]
Merge branch 'smattr/5dbb61ed-6813-47f4-918d-6a6047f05fa9' into 'main'

simplification and reduction of macros

See merge request graphviz/graphviz!2402

2 years agoremove no-op 'agattrrec' casts
Matthew Fernandez [Fri, 14 Jan 2022 02:05:26 +0000 (18:05 -0800)]
remove no-op 'agattrrec' casts

2 years agoremove no-op 'agdatadict' casts
Matthew Fernandez [Fri, 14 Jan 2022 02:05:10 +0000 (18:05 -0800)]
remove no-op 'agdatadict' casts

2 years agoAPI BREAK: remove 'NIL' macros
Matthew Fernandez [Fri, 14 Jan 2022 01:58:05 +0000 (17:58 -0800)]
API BREAK: remove 'NIL' macros

2 years agoremove use of 'NIL'
Matthew Fernandez [Fri, 14 Jan 2022 01:50:17 +0000 (17:50 -0800)]
remove use of 'NIL'

2 years agouse C99 initialization to simplify 'Dtdisc_t' definitions
Matthew Fernandez [Fri, 14 Jan 2022 01:46:02 +0000 (17:46 -0800)]
use C99 initialization to simplify 'Dtdisc_t' definitions

2 years agoAPI BREAK: remove 'NOT' macro
Matthew Fernandez [Fri, 14 Jan 2022 01:08:48 +0000 (17:08 -0800)]
API BREAK: remove 'NOT' macro

2 years agoMerge branch 'smattr/7e470f6a-2599-44f5-92e8-0d1f12a223ff' into 'main'
Matthew Fernandez [Sat, 15 Jan 2022 17:12:50 +0000 (17:12 +0000)]
Merge branch 'smattr/7e470f6a-2599-44f5-92e8-0d1f12a223ff' into 'main'

move lib/mingle/edge_bundling.c to C++

See merge request graphviz/graphviz!2401

2 years agoedge_compatibility_full: use a C++ bool for 'flipped'
Matthew Fernandez [Thu, 13 Jan 2022 04:38:44 +0000 (20:38 -0800)]
edge_compatibility_full: use a C++ bool for 'flipped'

Gitlab: #2154

2 years agoedge_compatibility: use a C++ bool for 'flipped'
Matthew Fernandez [Thu, 13 Jan 2022 04:37:48 +0000 (20:37 -0800)]
edge_compatibility: use a C++ bool for 'flipped'

Gitlab: #2154