Skip to content

Commit

Permalink
Cleanup
Browse files Browse the repository at this point in the history
Signed-off-by: yamacir-kit <[email protected]>
  • Loading branch information
yamacir-kit committed Sep 21, 2023
1 parent 31eb3e3 commit c9d5970
Show file tree
Hide file tree
Showing 6 changed files with 26 additions and 26 deletions.
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ Subset of R7RS-small.
cmake -B build -DCMAKE_BUILD_TYPE=Release
cd build
make package
sudo apt install build/meevax_0.4.810_amd64.deb
sudo apt install build/meevax_0.4.811_amd64.deb
```

or
Expand Down Expand Up @@ -106,9 +106,9 @@ sudo rm -rf /usr/local/share/meevax

| Target Name | Description
|-------------|-------------
| `all` | Build shared-library `libmeevax.0.4.810.so` and executable `meevax`
| `all` | Build shared-library `libmeevax.0.4.811.so` and executable `meevax`
| `test` | Test executable `meevax`
| `package` | Generate debian package `meevax_0.4.810_amd64.deb`
| `package` | Generate debian package `meevax_0.4.811_amd64.deb`
| `install` | Copy files into `/usr/local` directly

## Usage
Expand Down
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0.4.810
0.4.811
2 changes: 1 addition & 1 deletion include/meevax/kernel/input_string_port.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ inline namespace kernel

namespace literals
{
auto operator ""_read(char const*, std::size_t) -> object;
auto operator ""_r(char const*, std::size_t) -> object;
} // namespace literals
} // namespace kernel
} // namespace meevax
Expand Down
4 changes: 2 additions & 2 deletions script/unicode.sh
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@ input="$(git rev-parse --show-toplevel)/configure/UnicodeData.txt"
for each in "$@"
do
case "$each" in
--property ) sed -E 's/^([^;]*);([^;]*;){01}([^;]*).*$/case 0x\1: return \3;/g' "$input" ;;
--digit-value ) sed -E 's/^([^;]*);([^;]*;){06}([^;]*).*$/case 0x\1: return \3;/g' "$input" | grep -e 'case 0x.\+: return .\+;' ;;
--property ) sed -E 's/^([^;]*);([^;]*;){01}([^;]*).*$/case 0x\1: return \3;/g' "$input" ;;
--digit-value ) sed -E 's/^([^;]*);([^;]*;){06}([^;]*).*$/case 0x\1: return \3;/g' "$input" | grep -e 'case 0x.\+: return .\+;' ;;
--upcase ) sed -E 's/^([^;]*);([^;]*;){11}([^;]*).*$/case 0x\1: return 0x\3;/g' "$input" | grep -e 'case 0x.\+: return 0x.\+;' ;;
--downcase ) sed -E 's/^([^;]*);([^;]*;){12}([^;]*).*$/case 0x\1: return 0x\3;/g' "$input" | grep -e 'case 0x.\+: return 0x.\+;' ;;
esac
Expand Down
2 changes: 1 addition & 1 deletion src/kernel/input_string_port.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ inline namespace kernel

namespace literals
{
auto operator ""_read(char const* s, std::size_t) -> object
auto operator ""_r(char const* s, std::size_t) -> object
{
return input_string_port(s).read();
}
Expand Down
36 changes: 18 additions & 18 deletions src/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -25,31 +25,31 @@ auto main(int const argc, char const* const* const argv) -> int

return with_exception_handler([&]()
{
auto interact = [&](auto & environment)
auto interact = [&](environment & e)
{
if (environment.configure(argc, argv); environment.interactive)
if (e.configure(argc, argv); e.interactive)
{
environment.import("(scheme base)"_read);
environment.import("(scheme case-lambda)"_read);
environment.import("(scheme char)"_read);
environment.import("(scheme complex)"_read);
environment.import("(scheme cxr)"_read);
environment.import("(scheme eval)"_read);
environment.import("(scheme file)"_read);
environment.import("(scheme inexact)"_read);
environment.import("(scheme lazy)"_read);
environment.import("(scheme load)"_read);
environment.import("(scheme process-context)"_read);
environment.import("(scheme read)"_read);
environment.import("(scheme repl)"_read);
environment.import("(scheme time)"_read);
environment.import("(scheme write)"_read);
e.import("(scheme base)"_r);
e.import("(scheme case-lambda)"_r);
e.import("(scheme char)"_r);
e.import("(scheme complex)"_r);
e.import("(scheme cxr)"_r);
e.import("(scheme eval)"_r);
e.import("(scheme file)"_r);
e.import("(scheme inexact)"_r);
e.import("(scheme lazy)"_r);
e.import("(scheme load)"_r);
e.import("(scheme process-context)"_r);
e.import("(scheme read)"_r);
e.import("(scheme repl)"_r);
e.import("(scheme time)"_r);
e.import("(scheme write)"_r);

while (standard_input_port().good())
{
try
{
std::cout << u8"\u03bb> " << environment.evaluate(standard_input_port().read()) << std::endl;
std::cout << u8"\u03bb> " << e.evaluate(standard_input_port().read()) << std::endl;
}
catch (error const& error)
{
Expand Down

0 comments on commit c9d5970

Please sign in to comment.