Comments (3)
from freefem-sources.
I think there is a bug in mylex::xxxx::open
in src/fflib/lex.cpp.
If FF_INCLUDEPATH is empty (i.e. lex->includedir), then the code tries to open ff (i.e. filename). It is ok.
However, if FF_INCLUDEPATH is not empty, then it tries to prepend ff with each path in FF_INCLUDEPATH without trying to open ff alone. But the error message in case of failure says that opening ff failed while it is actually false (even though it is actually the expected behavior). So, I think I will need to modify the original algorithm.
Furthermore, as I would like to modify the behavior of include
directive, I need to know in which order files should be searched for. For example, let say that $FF_ROOT/foo.edp includes bar.edp and that it is run from $SOMEWHERE. What is the order of trials?
- $FF_ROOT/bar.edp, then $FF_INCLUDEPATH/bar.edp, then $SOMEWHERE/bar.edp
- $FF_INCLUDEPATH/bar.edp, then $FF_ROOT/bar.edp, then $SOMEWHERE/bar.edp
- $SOMEWHERE/bar.edp, then $FF_ROOT/bar.edp, then $FF_INCLUDEPATH/bar.edp
- $SOMEWHERE/bar.edp, then $FF_INCLUDEPATH/bar.edp, then $FF_ROOT/bar.edp
Something else?
from freefem-sources.
After checking, there is no bug in the code. I make a PR with the following behavior:
- the file is searched with no path
- then the file is searched with the path to the directory of the file which includes it
- then the file is searched with paths contained in includedir (FF_INCLUDEPATH and more)
Therefore, only step 2 is new.
from freefem-sources.
Related Issues (20)
- PETSc and export .vtu files HOT 1
- BDM finite element HOT 1
- A higher BDM finite element HOT 1
- error: use of overloaded operator '=' is ambiguous (with operand types 'KN<idx_t>' (aka 'KN<long>') and 'int') HOT 3
- The test LapEigenBeltrami.edp fails HOT 7
- Does Freefem have a quadrilateral element? HOT 2
- no match for ‘operator==’ (operand types are ‘const Cplx {aka const std::complex<double>}’ and ‘__complex__ double’) HOT 2
- Calculations stop when the plot window is minimized HOT 1
- MacOS install Error, libumfpack.6.dylib no such file HOT 2
- FFGlut error on release 4.13
- Adaptation does not converge with mshmet/mmg3d HOT 1
- configure fails to find ipopt because it looks for the header in a wrong place
- configure fails to find scotch because of: error: unknown type name 'int64_t' HOT 4
- problems when compiling on RH Linux HOT 7
- FAIL: testvtk.edp HOT 1
- Problems compiling on OpenSUSE 15.4 HOT 7
- Deprecated URL for MUMPS download in 3rdparty/getall HOT 3
- more deprecated URL download in ./3rdparty/getall HOT 2
- origin of 2D-meshes appear at [0,0] instead of at the chosen coordinate HOT 2
- Unable to install FreeFEM++ Error at step: ./3rdparty/getall -a 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 freefem-sources.