Bug 3382 – [tdpl] Implement uniform function call syntax

Status
RESOLVED
Resolution
FIXED
Severity
normal
Priority
P2
Component
dmd
Product
D
Version
D2
Platform
All
OS
All
Creation time
2009-10-09T03:38:00Z
Last change time
2012-03-08T02:17:51Z
Keywords
patch, TDPL
Assigned to
nobody
Creator
doob
Depends on
6277

Attachments

IDFilenameSummaryContent-TypeSize
470dmd.patchThe patch partly implements this enhancementtext/plain1206

Comments

Comment #0 by doob — 2009-10-09T03:38:28Z
Created attachment 470 The patch partly implements this enhancement This is a suggestion to implement the uniform function call syntax that was talked about in the first D conference. See the newsgroup thread for more info: http://www.digitalmars.com/webnews/newsgroups.php?art_group=digitalmars.D&article_id=97654 I've supplied a patch that partly implements this enhancement. Literals don't work with the patch, this works with the patch: x.foo(), this doesn't work: 3.foo(). I think the parser or similar must be changed for 3.foo() to work. I'm not sure if any of the added types in the patch should be removed or if some other types should be added.
Comment #1 by torarind — 2010-09-01T05:49:36Z
This is feature is described in TDPL under 5.9.1 "Pseudo Members and @property Attribute".
Comment #2 by bus_dbugzilla — 2011-11-18T07:33:09Z
*** Issue 6970 has been marked as a duplicate of this issue. ***
Comment #3 by k.hara.pg — 2011-12-26T05:42:06Z
Related: - Issue 662 - Allow UFCS for basic types and enums - Issue 6277 - Disallow short floating point literals
Comment #4 by k.hara.pg — 2011-12-26T06:16:50Z
Comment #5 by github-bugzilla — 2012-03-07T23:19:18Z
Commit pushed to master at https://github.com/D-Programming-Language/dmd https://github.com/D-Programming-Language/dmd/commit/b7742f7a733ff73d364c6ed54af70d875d7e911b Merge pull request #582 from 9rnsr/fix3382_ufcs Issue 3382 - [tdpl] Implement uniform function call syntax