14

So a while back I was searching for an unused high-application order symbol I could use for an OOP framework and I ran across InlinePart (esc @> esc) in my UnicodeCharacters.tr file with an application precedence of 763 (e.g. when parsing an expression using this its formatting rules are called before those of, say, []).

When I actually use the symbol though I get this:

In[63]:= a \[InlinePart] b[10]

Out[63]= RowBox[{a, InlinePart, b}][10]

For those curious the symbol looks like this: row part

And the only reference I could find to it (outside of styling stuff or other formatting things) was this.

So what was it? Why'd it go?

b3m2a1
  • 46,870
  • 3
  • 92
  • 239
  • I also found nothing. Not via PrintDefinitions nor anwhere else in the documentation nor in the Internet. Only a file where the shortcut was defined you've already given. I like to think, that this is simple a symbol Wolfram reserved for something a user could use for implementing new things like you want to. But i doubt it. I experimented a little bit with it but didn't found any particular use-case or other pattern beside the one already observed. This is strange. So: good question. – Julien Kluge Dec 31 '16 at 02:21
  • I think it was removed based on the chat I found / linked to. R. M. seemed to know what it was so hopefully he will stop by and enlighten us poor souls. – b3m2a1 Dec 31 '16 at 02:27
  • Interesting discovery. I'll have to read that file more carefully. Note also the behavior of InlinePart[a, b] – Mr.Wizard Dec 31 '16 at 07:50
  • And if you do System`Private`HasAnyCodesQ@InlinePart it appears to have been scrubbed from the kernel too. – b3m2a1 Dec 31 '16 at 13:26

1 Answers1

14

InlinePart or @> was an operator that was introduced in one of the pre-release/betas for version 10 and subsequently removed before public release. It was briefly available publicly in the Raspberry Pi version of Wolfram Language that co-existed with the pre-releases at the time.

The operator allowed you to access elements of a list with an infix operator. Both of these would have been equivalent:

list = {1, 2, 3};

list @> 2 (* InlinePart *)
list[[2]] (* Part *)

I think it was also more flexible than that and allowed you to access keys of Associations with assoc @> "key" syntax. The thinking probably might have been that this syntactic sugar would make it easy to chain or "drill" into a dataset with dataset @> key1 @> key2 @> key3

If I had to guess why it was discontinued, I would think that it was because it didn't bring much to the table while adding a lot of overhead (both for the end user and for the developers) and fundamentally altering a core symbol Part.

  • You couldn't use ;; or Span for flexible indexing.
  • There is the potential for visual confusion with @ and friends.
  • I don't remember, but there might have been some precedence issues as well. For example, f @ g @> 2 might have been parsed as (f @ g) @> 2 instead of f @ (g @> 2) which is different from using [[]] (I could be misremembering this).

I think in lieu of this operator, Associations was modified to support the function call syntax so that you could do assoc @ "key" which achieved the same while being more idiomatic/Mathematica like.

My memory is hazy and some parts about the motivations are speculative, but I think this is a fair summary of what this operator did during its short life. Taliesin Beynon will know more about this if you're really interested in an authoritative answer :)

rm -rf
  • 88,781
  • 21
  • 293
  • 472
  • Thanks a bunch. Its high parsing precedence and interesting appearance made me want it for overloading property calls, but then I just got really curious. – b3m2a1 Jan 06 '17 at 06:30
  • In the notebook front end, if you type \[In you get a drop-down list of autocompletion suggestions. \[InlinePart] is in that list (as is \[InvisibleApplication], one of my favorites. It appears that the documentation and evaluation rules of of \[InlinePart] have been removed, but not all traces of its existence. You will get the appropriate Unicode character and the RowBox result as in the originally posted question, at least in MMA 11.0.3 on Linux. – Reb.Cabin Dec 19 '18 at 16:08