[Progress Communities] [Progress OpenEdge ABL] Forum Post: Implied data conversion (casting) of non-class code

  • Thread starter Thread starter jmartin104
  • Start date Start date
Status
Not open for further replies.
J

jmartin104

Guest
I can't seem to locate it, but I'm assuming OpenEdge allows implied data conversion. Is this documented? For example, the code below does not generate an error or warning. According to online documentation " The parameters specified by parameter must match in number and order, according to mode and data type , as required by the given procedure... " "The AVM implicitly converts passed parameter values of certain data types from a narrow data type in the source to a widened data type in the destination, depending on the parameter mode. A widened data type is one that can hold all the values of a narrower data type without loss of data. Widening is supported for three related sets of data types, as shown in the following table, where the arrow ( —>) indicates the direction that a value can be passed for the parameter." - (Parameter Passing Syntax) However, the table does not seem to indicate anything other than a longchar as valid for a char. def var myInt as int no-undo init 7. run myProc(myInt). procedure myProc: define input param myChar as char no-undo. disp myChar. end.

Continue reading...
 
Status
Not open for further replies.
Back
Top