Try this instead:
round(decimal-date-time(${today}) - decimal-date-time(${dateofbirth}),0)
The decimal-date-time() function converts a DATE type to the number of days since a predefined epoch (Jan 1 1970 as it happens). So taking the difference gives you the number of days between today and the date of birth. [so if you want years, months, or weeks instead then divide this # days value appropriately].