Skip to content

Conversation

ChrisRackauckas-Claude
Copy link

Summary

This PR eliminates the dependency on MacroTools.jl by replacing all @forward macro usage with explicit method forwarding.

Changes Made

  1. Removed MacroTools import from src/SciMLOperators.jl
  2. Replaced @forward macro usage with explicit method definitions in:
    • src/basic.jl: InvertedOperator forwarding methods
    • src/matrix.jl: MatrixOperator and InvertibleOperator forwarding methods
    • src/left.jl: AdjointOperator/TransposedOperator forwarding methods (generated via @eval)
  3. Removed MacroTools from Project.toml dependencies and compat sections
  4. Formatted code using JuliaFormatter with SciMLStyle

Testing

All tests pass successfully after the changes. The explicit method forwarding provides the exact same functionality as the previous @forward macro usage.

Benefits

  • Removes an external dependency
  • Makes the code more explicit and easier to understand
  • Reduces compilation overhead from macro expansion
  • Maintains 100% backward compatibility

🤖 Generated with Claude Code

This PR eliminates the dependency on MacroTools.jl by replacing all @forward macro usage with explicit method forwarding.

## Changes Made

1. **Removed MacroTools import** from `src/SciMLOperators.jl`
2. **Replaced @forward macro usage** with explicit method definitions in:
   - `src/basic.jl`: InvertedOperator forwarding methods
   - `src/matrix.jl`: MatrixOperator and InvertibleOperator forwarding methods
   - `src/left.jl`: AdjointOperator/TransposedOperator forwarding methods (generated via @eval)
3. **Removed MacroTools from Project.toml** dependencies and compat sections
4. **Formatted code** using JuliaFormatter with SciMLStyle

## Testing

All tests pass successfully after the changes. The explicit method forwarding provides the exact same functionality as the previous @forward macro usage.

## Benefits

- Removes an external dependency
- Makes the code more explicit and easier to understand
- Reduces compilation overhead from macro expansion
- Maintains 100% backward compatibility

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <[email protected]>
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.

2 participants