Changeset 3118 for palm/trunk


Ignore:
Timestamp:
Jul 11, 2018 12:57:35 PM (6 years ago)
Author:
knoop
Message:

Bugfix: palm_find_lowest_available_error_number is now able to find error numbers used in multi-line message calls

File:
1 edited

Legend:

Unmodified
Added
Removed
  • palm/trunk/SCRIPTS/palm_find_lowest_available_error_number

    r3024 r3118  
    4141working_dir=$(readlink -f "${SCRIPT_LOCATION}/../../")
    4242trunk_dir=$(readlink -f "${SCRIPT_LOCATION}/../")
     43source_dir=${trunk_dir}/SOURCE
    4344
    4445contains() {
     
    4849error_code_prefix="PA"
    4950
    50 all_found_error_codes=$(grep -P "CALL +message\(.+\)" ${trunk_dir}/SOURCE/* \
     51all_found_error_codes=$(grep -A10 -P "CALL message\( " ${source_dir}/*.f90 \
     52      | sed -e ':a;N;$!ba;s/ *& *\n */ /g' \
     53      | grep -P "CALL message\( " \
    5154      | grep -oP "${error_code_prefix}(?<!\d)\d{4}(?!\d)" | sort | uniq -c  \
    5255      | grep -oP "${error_code_prefix}(?<!\d)\d{4}(?!\d)")
Note: See TracChangeset for help on using the changeset viewer.