Case one: Life after delivery was established, then the child died. Naming, washing and funeral prayer are prescribed.
Case two: No reliable evidence of life after delivery; burial in cloth is performed but the funeral prayer is not offered under the stated Hanafi ruling.
The central distinction is evidence of post-birth life, not the infant’s size or merely the duration of pregnancy.