-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
10 changed files
with
72 additions
and
28 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,37 +1,49 @@ | ||
from typing import Dict | ||
from typing import Dict, Tuple | ||
import enum | ||
|
||
class CStandard(enum.Enum): | ||
|
||
def __init__(self, version: int, d: Dict[str, bool]) -> None: | ||
def __init__(self, name: str, d: Dict[str, bool]) -> None: | ||
self.anon_unions = d.get("anon_unions", False) | ||
self.static_assert = d.get("static_assert", False) | ||
self.static_assert_needs_assert_h = d.get("static_assert_needs_assert_h", False) | ||
|
||
# Prevent Enum from flattening members into aliases | ||
self._value_ = version | ||
self._value_ = name | ||
|
||
gnu23 = 23, { | ||
gnu23 = "gnu23", { | ||
"anon_unions": True, | ||
"static_assert": True, | ||
} | ||
|
||
gnu17 = 17, { | ||
gnu17 = "gnu17", { | ||
"anon_unions": True, | ||
"static_assert": True, | ||
"static_assert_needs_assert_h": True, | ||
} | ||
|
||
gnu11 = 11, { | ||
gnu11 = "gnu11", { | ||
"anon_unions": True, | ||
"static_assert": True, | ||
"static_assert_needs_assert_h": True, | ||
} | ||
|
||
gnu99 = 99, {} | ||
gnu99 = "gnu99", { | ||
"anon_unions": False, | ||
"static_assert": False, | ||
"static_assert_needs_assert_h": False, | ||
} | ||
|
||
gnu90 = 90, {} | ||
gnu90 = "gnu90", { | ||
"anon_unions": False, | ||
"static_assert": False, | ||
"static_assert_needs_assert_h": False, | ||
} | ||
|
||
gnu89 = 89, {} | ||
gnu89 = "gnu89", { | ||
"anon_unions": False, | ||
"static_assert": False, | ||
"static_assert_needs_assert_h": False, | ||
} | ||
|
||
latest = gnu17 # gnu23 is still unreleased |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
[mypy] | ||
namespace_packages = True | ||
explicit_package_bases = True | ||
|
||
[mypy-systemrdl.*] | ||
# Ignore missing py.typed in release | ||
ignore_missing_imports = True | ||
|
||
[mypy-peakrdl.*] | ||
# Ignore missing py.typed in release | ||
ignore_missing_imports = True |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters