• R/O
  • SSH

提交

标签
No Tags

Frequently used words (click to add to your profile)

javac++androidlinuxc#windowsobjective-ccocoa誰得qtpythonphprubygameguibathyscaphec計画中(planning stage)翻訳omegatframeworktwitterdomtestvb.netdirectxゲームエンジンbtronarduinopreviewer

Castle: The best Real-Time/Embedded/HighTech language EVER. Attempt 2


Commit MetaInfo

修订版b36d513ce3001f5c9b9677d72513adb67a052e7b (tree)
时间2024-03-10 01:47:02
作者Albert Mietus < albert AT mietus DOT nl >
CommiterAlbert Mietus < albert AT mietus DOT nl >

Log Message

Added doc: Parameter/Argument

更改概述

差异

diff -r df1a9a3baec7 -r b36d513ce300 base_packages/castle-aigr/castle/aigr/aid.py
--- a/base_packages/castle-aigr/castle/aigr/aid.py Sat Mar 09 17:09:51 2024 +0100
+++ b/base_packages/castle-aigr/castle/aigr/aid.py Sat Mar 09 17:47:02 2024 +0100
@@ -12,16 +12,18 @@
1212
1313 @dataclass
1414 class TypedParameter(AIGR):
15- """This is many a helper class/struct to combine a parameter: a name and an type"""
16- name: str
15+ """A parameter is a variable in a function/callable **definition**.
16+ It acts as placeholder and has no specific value. In Castle, it always has a Type."""
17+ name: str # XXX ToDo str or ID?
1718 type: type
1819
1920 @dataclass
2021 class Argument(AIGR):
21- """This is many a helper class/struct to combine a argument: a value and optional a name"""
22+ """An argument is a value passed during function/callable **invocation**.
23+ In Castle, we support both positional and named arguments. Hence, an argument can have a name."""
2224 value: PTH.Any
2325 _: KW_ONLY
24- name: PTH.Optional[str]=None
26+ name: PTH.Optional[str]=None # XXX ToDo str or ID?
2527
2628
2729 @dataclass