Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add fs #34

Merged
merged 5 commits into from
Sep 6, 2024
Merged

add fs #34

merged 5 commits into from
Sep 6, 2024

Conversation

lijunchen
Copy link
Contributor

No description provided.

@lijunchen lijunchen marked this pull request as ready for review August 2, 2024 03:09
Copy link

peter-jerry-ye-code-review bot commented Sep 4, 2024

  1. Potential Typos and Inconsistent Function Naming:

    • In fs/fs.mbti, the function write_string is defined, but in fs/fs.wasm-gc.mbt, an internal function _write_string is used. These should ideally be consistent to avoid confusion.
    • Similarly, read_to_string in fs/fs.mbti maps to _read_to_string in fs/fs.wasm-gc.mbt. Consider using the same function names unless there's a specific reason for the distinction.
  2. Incomplete Documentation:

    • The documentation in fs/fs.wasm-gc.mbt for _write_string is missing. It should include a complete description, parameters, and return values similar to other documented functions in the same file.
  3. Error Handling in Function Calls:

    • In fs/fs.wasm-gc.mbt, the function read_to_string checks if the file exists using exists(~path) and then calls _read_to_string(path). However, it might be more robust to include explicit error handling in _read_to_string to manage any potential issues encountered during file reading operations, not just the existence check.

@lijunchen lijunchen merged commit ff5d85e into main Sep 6, 2024
8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant