Skip to content

Commit eef2e10

Browse files
committed
Merge pull request #11 from praisetompane/3_data_model
docs: object definition. clean up setup
2 parents ef4d0e8 + bc1d9b1 commit eef2e10

File tree

18 files changed

+112
-89
lines changed

18 files changed

+112
-89
lines changed

.spellcheck_exceptions_dictionary.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,6 @@ pycache
4040
IndentationError
4141
TabError
4242
SyntaxError
43-
datamodel
4443
coroutines
4544
lexemes
4645
lexically
@@ -138,6 +137,7 @@ PyData
138137

139138

140139
# urls:
140+
datamodel
141141
pkgs
142142
readthedocs
143143
src

.tool-versions

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
python 3.12.3
1+
python 3.13.2
File renamed without changes.
Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
def data model:
2+
- formal: ???
3+
4+
- in words: ???
5+
6+
- plain english: ???
7+
8+
- intuition: ???
9+
10+
- properties: ???
11+
12+
- examples: ???
13+
14+
- use cases:
15+
- a means by which we can implement protocols(Powell, 2017)
16+
the protocol meaning is determined by the specific type.
17+
example:
18+
- __add__ for a string means concatenate
19+
- __add__ for a Polynomial means add the coefficients
20+
- ...
21+
22+
- proof: ???
23+
24+
References:
25+
Powell, J. 2017. What Does It Take To Be An Expert At Python. PyData
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
def object:
2+
- formal: ???
3+
- in words: ???
4+
5+
- plain english: Python's abstraction for data and code.
6+
7+
- intuition: ???
8+
9+
- properties:
10+
- id
11+
- value
12+
- type
13+
- implementation:
14+
- cpython:
15+
- PyTypeObject
16+
- type system: https://typing.python.org/en/latest/spec/index.html
17+
18+
- operations:
19+
- is: compares object identity
20+
- id(object): returns an object's identity memory address(in cpython)
21+
22+
- implementation:
23+
- cpython:
24+
- id(object) = memory address
25+
- examples: ???
26+
27+
- use cases: ???
28+
29+
- proof: ???
30+
31+
References: ???
32+
Python Software Foundation. 2023. Objects, values and types. https://docs.python.org/3.12/reference/datamodel.html#objects-values-and-types

1_core_language/3_datamodel/2_the_standard_type_hierarchy/def.py renamed to 1_core_language/3_data_model/2_the_standard_type_hierarchy/def.py

File renamed without changes.

1_core_language/3_datamodel/2_the_standard_type_hierarchy/def.txt renamed to 1_core_language/3_data_model/2_the_standard_type_hierarchy/def.txt

File renamed without changes.

1_core_language/3_datamodel/3_special_method_names/def.txt renamed to 1_core_language/3_data_model/3_special_method_names/def.txt

File renamed without changes.
File renamed without changes.

1_core_language/3_datamodel/0_def.txt

Lines changed: 0 additions & 24 deletions
This file was deleted.

0 commit comments

Comments
 (0)