mirror of
https://github.com/RustPython/RustPython.git
synced 2026-10-28 18:59:04 +08:00
Update __hello__ and __phello__ from cpython
This commit is contained in:
1 parent
496006d629
commit
ad20a404a9
8 files changed
+38
-5
No files matched your search
Vendored
+16
@@ -0,0 +1,16 @@
|
||||
initialized = True
|
||||
|
||||
class TestFrozenUtf8_1:
|
||||
"""\u00b6"""
|
||||
|
||||
class TestFrozenUtf8_2:
|
||||
"""\u03c0"""
|
||||
|
||||
class TestFrozenUtf8_4:
|
||||
"""\U0001f600"""
|
||||
|
||||
def main():
|
||||
print("Hello world!")
|
||||
|
||||
if __name__ == '__main__':
|
||||
main()
|
||||
Vendored
+7
@@ -0,0 +1,7 @@
|
||||
initialized = True
|
||||
|
||||
def main():
|
||||
print("Hello world!")
|
||||
|
||||
if __name__ == '__main__':
|
||||
main()
|
||||
Vendored
Whitespace-only changes.
Vendored
Whitespace-only changes.
Vendored
+7
@@ -0,0 +1,7 @@
|
||||
initialized = True
|
||||
|
||||
def main():
|
||||
print("Hello world!")
|
||||
|
||||
if __name__ == '__main__':
|
||||
main()
|
||||
+1
@@ -0,0 +1 @@
|
||||
../../../Lib/__hello__.py
|
||||
+1
@@ -0,0 +1 @@
|
||||
../../../Lib/__phello__
|
||||
+6
-5
@@ -11,11 +11,12 @@ pub fn core_frozen_inits() -> impl Iterator<Item = (String, FrozenModule)> {
|
||||
};
|
||||
}
|
||||
|
||||
ext_modules!(
|
||||
iter,
|
||||
source = "initialized = True; print(\"Hello world!\")\n",
|
||||
module_name = "__hello__",
|
||||
);
|
||||
// keep as example but use file one now
|
||||
// ext_modules!(
|
||||
// iter,
|
||||
// source = "initialized = True; print(\"Hello world!\")\n",
|
||||
// module_name = "__hello__",
|
||||
// );
|
||||
|
||||
// Python modules that the vm calls into, but are not actually part of the stdlib. They could
|
||||
// in theory be implemented in Rust, but are easiest to do in Python for one reason or another.
|
||||
|
||||
Reference in new issue
Block a user