File tree Expand file tree Collapse file tree 1 file changed +9
-6
lines changed Expand file tree Collapse file tree 1 file changed +9
-6
lines changed Original file line number Diff line number Diff line change @@ -649,12 +649,15 @@ reverse(t::Tuple) = revargs(t...)
649649
650650# # specialized reduction ##
651651
652- prod (x:: Tuple{} ) = 1
653- # This is consistent with the regular prod because there is no need for size promotion
654- # if all elements in the tuple are of system size.
655- # It is defined here separately in order to support bootstrap, because it's needed earlier
656- # than the general prod definition is available.
657- prod (x:: Tuple{Int, Vararg{Int}} ) = * (x... )
652+ # used in bootstrapping
653+ function prod (x:: Tuple{Vararg{Int}} )
654+ @_terminates_locally_meta
655+ r = 1
656+ for y in x
657+ r *= y
658+ end
659+ r
660+ end
658661
659662# a version of `in` esp. for NamedTuple, to make it pure, and not compiled for each tuple length
660663function sym_in (x:: Symbol , itr:: Tuple{Vararg{Symbol}} )
You can’t perform that action at this time.
0 commit comments