Comments (4)
Seems like this would have to be a 2.0 thing, if it's practical at all. We certainly can't change any of the existing infix operators to behave this way.
The basic issue here is that operator precedence is determined by the parser, which acts before any user definitions are loaded.
Closely related to #16985.
from julia.
Also related: #18714
I think without more specifics this issue isn't actionable though. If there is a new proposed operator we don't yet parse, it can be added in this way, or if there are existing operators that should be changed (ergo 2.0) they should be listed explicitly.
from julia.
One that might even be doable in 1.x is 2 .^ 1:5
which I can't imagine anybody doing on purpose.
As for 2.0, I think perhaps even most operators might be better off with this treatment absent some strong particularized argument for each one (such as the strong and universal convention on +-*/^()
etc). Supporting code like w ⩋ x ⩍ y ⩎ z
does no favors for readability, at least for me.
from julia.
this question might be dumb, but what is preventing treating consecutive operators as a new operator?
from julia.
Related Issues (20)
- 1.11.0-alpha2: problems with precompilation HOT 3
- Destructed arguments cannot be properly used to define optional arguments HOT 1
- Missing documentation: sortperm! is not truly non-allocating unless scratchspace is provided HOT 6
- `x < min(x, y)` HOT 11
- Illegal instruction on 1.10.2 but not 1.11+ HOT 3
- Unreachable reached at 0x7b92c0862a74 / Illegal instruction
- Illegal instruction crash
- Defining `==` for `ComposedFunction` by comparing `inner` and `outer` HOT 1
- the GenericMemory doc string isn't included in the docs HOT 3
- Add `mul_hi` HOT 10
- Building from fresh clone with `USECCACHE=1` fails
- `Base.FastMath.pow_fast(a::Float64, i::Int)` fails for huge `i` HOT 6
- Parallel precompile shows stacktrace into precompilation code when a package fails to precompile
- Parallel precompile now seems to fail precompiling the package itself HOT 9
- Broadcasts over `StepRange` of `Date/DateTime` materialize to vectors
- Container Closure Integrity Testing Market Size, Growth Strategies, Competitive Landscape, Factor Analysis, 2035 HOT 1
- BUG: `^(::Float64, ::Union{Int, Float64})` incorrect for very large negative exponents HOT 10
- REPL: path completion hints shouldn't expand `~` to user dir
- Loading test "relocatable upgrades" fails locally HOT 3
- generic method for `top_set_bit` gives wrong result 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 julia.