EDIT: Your comment has been substantially edited so looks like I’ll have to do the same for mine.
“tttggg\n”, since Perl “reverse” is for reversing lists, right? But it’s not clear what that has to do with type inference. You seem to once again be using “type inference” to mean “implicit type conversion”. There’s no need to call this “type inference” because it already had a name. If Perl used type inference—and did not implicitly convert between scalars and lists of one scalar—the program would never even start, because it would contain a type error. Again, the notion of “type inference” only applies in a static typing system, so it’s not really applicable to Perl.
If you want an actual definition, then here is my attempt: “Type inference” refers to compile-time inference of types so that type errors can be detected.
EDIT: Your comment has been substantially edited so looks like I’ll have to do the same for mine.
“tttggg\n”, since Perl “reverse” is for reversing lists, right? But it’s not clear what that has to do with type inference. You seem to once again be using “type inference” to mean “implicit type conversion”. There’s no need to call this “type inference” because it already had a name. If Perl used type inference—and did not implicitly convert between scalars and lists of one scalar—the program would never even start, because it would contain a type error. Again, the notion of “type inference” only applies in a static typing system, so it’s not really applicable to Perl.
If you want an actual definition, then here is my attempt: “Type inference” refers to compile-time inference of types so that type errors can be detected.