question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Add custom operator definition syntax

See original GitHub issue

Suggested Syntax:

def <arg> ` <op> ` <arg>:
    <body>
<arg> ` <op> ` <arg> = <body>

Issue Analytics

  • State:closed
  • Created 8 years ago
  • Comments:8 (7 by maintainers)

github_iconTop GitHub Comments

1reaction
evhubcommented, Dec 28, 2018

@narfanar This was replaced with infix function notation, e.g. 5 `mod` 3. Though this might still be worth implementing, so I’ll reopen it.

0reactions
evhubcommented, Oct 4, 2022

This is now live on coconut-develop>=2.0.0-post_dev4! Check out the develop documentation for more info.

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to create custom operators and do operators overloading ...
An operator is a special symbol that you use with one or more values to produce a specific result. For example, the addition...
Read more >
Custom operators in Swift - Swift by Sundell
Let's see if introducing a new operator can help us clean up this code a bit. Adding a new operator. We'll start by...
Read more >
Can you make custom operators in C++? - Stack Overflow
There's a method thoroughly explored in 'Syntactic Aspartame' by Sander ... Adding custom operators like this can easily lead to a sort of...
Read more >
Don't fear the custom operators!. Operator (+ - Medium
In swift, one can define custom operator. ... Surely the operator looks nice and conveys the addition intent.
Read more >
Operator overloading - Define unary, arithmetic, equality, and ...
You also use the operator keyword to define a custom type conversion. For more information, see User-defined conversion operators. Overloadable ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found