Comments (1)
So I took a look into this. Originally I thought we could use the file!()
macro but then we are back to square one with not being able to have a macro evaluate as an input to another macro. Further, the path returned by file!()
is where the macro code lives not the file where the macro was called from.
I then started to look at using span to get this information out. Turns out you can use a span to get access to the calling file path, but currently it's an unstable feature. See this open issue
It provides a method on span pub fn source_file(&self) -> SourceFile;
This would allow us to get relative paths working, but the issue has been open for over 3 years, so there is a chance it might not land. Still, might be worth periodically checking in to see if there is any movement towards stabilizing this feature.
from fuels-rs.
Related Issues (20)
- Cannot call `msg_sender()` when creating multiple custom assets in Rust SDK HOT 1
- bug: `capacity overflow` while encoding param types
- test: `calculate_num_of_elements` is not tested
- Trim down variants of the `Error` type
- Improve Error wording for "not enough coins to fit the target"
- Add clippy check for overflowing arithmetic
- Error transfering custom assets of amount greater than the amount of owned base asset
- cargo test with harness.rs taking unrealistically long time to finish HOT 2
- Encoder/decoder revamp HOT 2
- Support the Sway's new `__log` encoding scheme
- test: check that the gas_forwarded test passes with enough ETH in the test wallet HOT 1
- Remove manual implemntations of `AbiEncode`
- “Response errors; not enough coins to fit the target” on Beta 5 with Rust SDK v0.54 HOT 4
- Single-byte optimization of `u8`s and `bool`s for `Configurable`s HOT 1
- Support the upcoming, new `dry_run` interface HOT 2
- Minimize the uniqueness of bytecodes HOT 2
- Tests fail when `fuel-core` is ran as a binary
- Random wallet creation cannot be given a randomness source
- Support new encoder/decoder for contracts
- Support new encoder/decoder for scripts and predicates HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from fuels-rs.