JuliaDebug / JuliaDebug/Debugger.jl
Entering to macro expansion?
Open
Nobody has claimed this yet.
- Dominant language
- Julia
- Stars
- 514
- Forks
- 50
- Avg merge
- 9d 9h
- Merged PRs (30d)
- 1
Description
It would be nice if it's possible to @enter into macro expansion code. I tried a simple approach like this
macro entermacro(ex)
@assert ex.head == :macrocall
quote
let f = getproperty($__module__, $(QuoteNode(ex.args[1]))),
ln = $(QuoteNode(ex.args[2])),
args = $(QuoteNode(Tuple(ex.args[3:end])))
@enter f(ln, $__module__, args...)
end
end
end
But it didn't work well as it looks like Debugger cannot fetch the source code of a macro.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the @enter and entermacro example in the issue and inspect how Debugger fetches source code for the macro call. Determine what support is needed for entering macro expansion code; done means @enter can enter the expansion and display its source reliably.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- julia
- Domain
- devtools
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100