Jira (PUP-7689) make it possible to invoke 'Type.new(e)' as e.Type()

6 views
Skip to first unread message

Henrik Lindberg (JIRA)

unread,
Jun 22, 2017, 6:47:02 AM6/22/17
to puppe...@googlegroups.com
Henrik Lindberg assigned an issue to Unassigned
 
Puppet / New Feature PUP-7689
make it possible to invoke 'Type.new(e)' as e.Type()
Change By: Henrik Lindberg
Assignee: Henrik Lindberg
Add Comment Add Comment
 
This message was sent by Atlassian JIRA (v6.4.14#64029-sha1:ae256fe)
Atlassian logo

Henrik Lindberg (JIRA)

unread,
Jun 22, 2017, 6:47:03 AM6/22/17
to puppe...@googlegroups.com
Henrik Lindberg created an issue
Issue Type: New Feature New Feature
Assignee: Henrik Lindberg
Components: Functions, Language, Type System
Created: 2017/06/22 3:46 AM
Fix Versions: PUP 5.1.0
Priority: Normal Normal
Reporter: Henrik Lindberg

At the moment it is not possible to make a new call at the end of a transformation. You need to do something like:

Hash($data.reduce |$memo, $entry| { ... })

because it is not possible to do this:

$data.reduce |$memo, $entry| { ... }).new(Hash)

What you want is the more natural left-to-right reading:

$data.reduce |$memo, $entry| { ... }.Hash

Karen Van der Veer (JIRA)

unread,
Aug 28, 2017, 11:31:03 AM8/28/17
to puppe...@googlegroups.com
Karen Van der Veer updated an issue
Change By: Karen Van der Veer
Fix Version/s: PUP 5.2.0
Fix Version/s: PUP 5.y

David McTavish (Jira)

unread,
Dec 6, 2021, 1:58:01 PM12/6/21
to puppe...@googlegroups.com
David McTavish updated an issue
Change By: David McTavish
Labels: usability
This message was sent by Atlassian Jira (v8.13.2#813002-sha1:c495a97)
Atlassian logo

David McTavish (Jira)

unread,
Dec 6, 2021, 1:58:01 PM12/6/21
to puppe...@googlegroups.com

Josh Cooper (Jira)

unread,
Jan 12, 2022, 1:40:02 PM1/12/22
to puppe...@googlegroups.com
Josh Cooper commented on New Feature PUP-7689
 
Re: make it possible to invoke 'Type.new(e)' as e.Type()

We don't have any plans on implementing this, so I'm going to close.

This message was sent by Atlassian Jira (v8.20.2#820002-sha1:829506d)
Atlassian logo
Reply all
Reply to author
Forward
0 new messages